package com.as.web;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import javax.servlet.http.HttpSession;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.as.base.BaseController;
import com.as.entity.User;

@Controller
@RequestMapping("/teacher")
public class TeacherController extends BaseController{
	@ResponseBody
	@RequestMapping("/getStudent")
	public Map<String, Object> getStudent(HttpSession httpSession){
		Map<String,Object> map = new HashMap<String, Object>();
		User user = (User)httpSession.getAttribute("user");
		List<User> list = userManager.getOneClassUser(user.getClassnum());
		map.put("userList", list);
		return map;
	}
}
